/*
 * @(#)NateUser.java
 *
 * Copyright (c) 1998-2005 Jang-Ho Hwang, 
 * All Rights Reserved.
 *
 * $Id: NateUser.java,v 1.1.1.1 2005/05/22 01:02:27 rath Exp $
 */
package rath.nateon;

/**
 * 네이트온 메신져 이벤트 리스너.
 * 
 * @author Jang-Ho Hwang, rath@xrath.com
 * @version 1.0.000, 2005/05/20
 */
public class NateUser 
{
	public static final String STATE_ONLINE = "O";
	public static final String STATE_OFFLINE = "F";
	public static final String STATE_BUSY = "B";
	public static final String STATE_AWAY = "A";
	public static final String STATE_PHONE = "P";
	public static final String STATE_MODERATE = "M";

	private long uid;
	private String email;
	private String name;
	private String nickname;
	private String state = STATE_OFFLINE;

	public NateUser()
	{

	}

	public void setId( long id )
	{
		this.uid = id;
	}

	public long getId()
	{
		return this.uid;
	}

	public void setEmail( String email )
	{
		this.email = email;
	}

	public String getEmail()
	{
		return this.email;
	}

	public void setName( String name )
	{
		this.name = name;
	}

	public String getName()
	{
		return this.name;
	}

	public void setNickname( String nickname )
	{
		this.nickname = nickname;
	}

	public String getNickname()
	{
		return this.nickname;
	}

	public boolean equals( Object o )
	{
		if( o!=null )
		{
			if( o instanceof NateUser && email.equals(((NateUser)o).email) )
				return true;
			if( o instanceof String && email.equals(o) )
				return true;
		}
		return false;
	}
}